package com.zh.common.utils;

import java.io.BufferedReader;
import java.io.InputStreamReader;

/**
 * 当前当前手机cpu架构
 */
public class CpuArchUtils {
    public static String getCpuArchitecture() {
        StringBuilder output = new StringBuilder();
        try {
            Process process = Runtime.getRuntime().exec("getprop ro.product.cpu.abi");
            BufferedReader reader = new BufferedReader(new InputStreamReader(process.getInputStream()));
            String line;
            while ((line = reader.readLine()) != null) {
                output.append(line);
            }
            reader.close();
            process.waitFor();
        } catch (Exception e) {
            e.printStackTrace();
        }
        return output.toString();
    }
}